package com.example.interfaces.dto;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import com.example.infrastructure.excel.ExcelExportable;
import com.example.infrastructure.excel.ExcelImportable;
import cn.idev.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import jakarta.validation.constraints.*;

/**
 * 问诊记录表 DTO
 *
 * @author wangal
 * @since 2025-07-25
 */
@Data
@Schema(name = "ConsultationsDTO", description = "问诊记录表DTO")
public class ConsultationsDTO implements ExcelExportable, ExcelImportable {

    @Schema(description = "问诊单号")
    @ExcelProperty("问诊单号")
    @NotBlank(message = "问诊单号不能为空")
    private String consultationNo;
    
    @Schema(description = "用户ID")
    @ExcelProperty("用户ID")
    @NotNull(message = "用户ID不能为空")
    private Long userId;
    
    @Schema(description = "医生ID")
    @ExcelProperty("医生ID")
    @NotNull(message = "医生ID不能为空")
    private Long doctorId;
    
    @Schema(description = "类型：1图文问诊，2视频问诊，3语音问诊")
    @ExcelProperty("类型：1图文问诊，2视频问诊，3语音问诊")
    private Byte consultationType;
    
    @Schema(description = "问诊标题")
    @ExcelProperty("问诊标题")
    @NotBlank(message = "问诊标题不能为空")
    private String title;
    
    @Schema(description = "问题描述")
    @ExcelProperty("问题描述")
    @NotBlank(message = "问题描述不能为空")
    private String description;
    
    @Schema(description = "图片附件，多个用逗号分隔")
    @ExcelProperty("图片附件，多个用逗号分隔")
    @NotBlank(message = "图片附件，多个用逗号分隔不能为空")
    private String images;
    
    @Schema(description = "问诊费用")
    @ExcelProperty("问诊费用")
    private BigDecimal consultationFee;
    
    @Schema(description = "状态：0待接诊，1问诊中，2已完成，3已取消，4已退款")
    @ExcelProperty("状态：0待接诊，1问诊中，2已完成，3已取消，4已退款")
    private Byte status;
    
    @Schema(description = "开始时间")
    @ExcelProperty("开始时间")
    private LocalDateTime startTime;
    
    @Schema(description = "结束时间")
    @ExcelProperty("结束时间")
    private LocalDateTime endTime;
    
    @Schema(description = "评分：1-5星")
    @ExcelProperty("评分：1-5星")
    private Byte rating;
    
    @Schema(description = "评价内容")
    @ExcelProperty("评价内容")
    @NotBlank(message = "评价内容不能为空")
    private String review;
    
    @Schema(description = "租户编号")
    @ExcelProperty("租户编号")
    @NotNull(message = "租户编号不能为空")
    private Long tenantId;
    
}
